package com.twu.biblioteca;

public class Item {
    protected String title;
    private boolean available = true;
    private User costumer = null;

    public Item(String title) {
        this.title = title;
    }

    public void checkOutBy(User costumer) {
        available = false;
        this.costumer = costumer;
    }

    public void checkIn() {
        available = true;
        this.costumer = null;
    }

    public String getTitle() {
        return title;
    }

    public boolean isAvailable() {
        return available;
    }

    public User getCostumer() {
        return costumer;
    }
}
